#include "CPPUtility.h"
#include <assert.h>

typedef std::map<std::string,int> ObjCountType;
ObjCountType Singleton::m_Type;
template<typename Type>
void Singleton::RegistSingleton(Type _classType)
{
	m_Type[typeid(_classType).name()] = 0;
}

template<typename Type>
void Singleton::UnRegistSingleton()
{
	
}


void Singleton::CheckSingleton()
{
	for(ObjCountType::iterator iter = m_Type.begin(); iter != m_Type.end(); ++iter)
	{
		if(iter->second > 1)
		{
			assert(0);
		}
	}
}